package com.gupaoedu.pattern.factory.simplefactory;

import com.gupaoedu.pattern.factory.Bread;
import com.gupaoedu.pattern.factory.Milk;

/**
 * 2019/5/4
 * created by chenpp
 */
public class FoodFactoryTest {
    public static void main(String[] args) {
        FoodFactory factory = new FoodFactory();
        Bread bread = (Bread) factory.productFood("bread" );
        Milk milk = (Milk)factory.productFood("milk" );
        bread.introduce();
        milk.introduce();


    }
}
